/** When your routing table is too long, you can split it into small modules **/

import Layout from '@/layout'

const nestedRouter = {
  level: 1,
  path: '/news',
  component: Layout,
  redirect: '/news',
  name: 'news',
  alwaysShow: true,
  meta: {
    title: '新闻中心',
    icon: 'news'
  },
  children: [
    {
      path: 'news1',
      name: 'news1',
      component: () => import('@/views/news/detail'), // Parent router-view
      meta: { title: '类型1' },
      roles: ['admin'] // or you can only set roles in sub nav
    }
  ]
}

export default nestedRouter
